<script setup lang="ts">
import ChildOne from './components/ChildOne.vue'
import ChildTwo from './components/ChildTwo.vue';
import { useCounterStore } from './stores/counter';
import { storeToRefs } from 'pinia'

// const store = useCounterStore()
// store.getChannelList()

const { channelList } = storeToRefs(useCounterStore())
const store = useCounterStore()
store.getChannelList()

</script>

<template>
  <div>
    <ChildOne />
    <ChildTwo />

    <ul>
      <li v-for="item in channelList" :key="item.id">
       {{ item.name }}
      </li>
    </ul>
  </div>
</template>

<style scoped></style>